-
Notifications
You must be signed in to change notification settings - Fork 1.3k
[Tooling] Use ReleasesV2 version as the source of truth during Code Freeze #22324
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Tooling] Use ReleasesV2 version as the source of truth during Code Freeze #22324
Conversation
92ad71d to
4ee319c
Compare
…of just showing a warning
4ee319c to
f6b5eb1
Compare
…hroughout code freeze lane
760d9e8 to
077ed62
Compare
|
I applied the following patch: and ran Running |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good. Didn't test locally because @twstokes already did that.
fastlane/Fastfile
Outdated
| version_name ||= VERSION_FILE.read_version_name | ||
| # Read the current release version from the .xcconfig file and parse it into an AppVersion object |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar to https://github.com/woocommerce/woocommerce-ios/pull/16296/files#r2512589279. We could move the comment back where the read happens:
| version_name ||= VERSION_FILE.read_version_name | |
| # Read the current release version from the .xcconfig file and parse it into an AppVersion object | |
| # Read the current release version from `version.properties` and parse it into an AppVersion object, | |
| # unless already provided | |
| version_name ||= VERSION_FILE.read_version_name |
or just do without:
| version_name ||= VERSION_FILE.read_version_name | |
| # Read the current release version from the .xcconfig file and parse it into an AppVersion object | |
| version_name ||= VERSION_FILE.read_version_name |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Tried to improve all the comments for this method on 70ceff9.
|



See AINFRA-1478
Description
This PR enhances the version handling added in the previous iteration to assume the version received by the code freeze lane as the source of truth, ignoring potential mismatches between the ReleasesV2 version and the project's computed version.
Testing
You can make sure the calculated release branch, current version and the next version are correctly shown in the "Continue" prompt. Just remember to answer
Nwhen asked to continue, to cancel the actual code freeze.To avoid unexpected results, comment out the lines doing
ensure_git_status_cleanandFastlane::Helper::GitHelper.checkout_and_pull(DEFAULT_BRANCH)at the beginning of the lane.You can run the
code_freezelane, with and without the version parameters:bundle exec fastlane code_freezebundle exec fastlane code_freeze version:30.6This will be fully tested in the next release cycle during code freeze.